package com.xywy.bloodandroid;

import android.os.Bundle;
import android.view.animation.AlphaAnimation;
import android.view.animation.Animation;
import android.view.animation.Animation.AnimationListener;
import android.widget.ImageView;

import com.xywy.bloodandroid.act.MainFragmentAct;
import com.xywy.bloodandroid.base.BaseActivity;

public class SplashActivity extends BaseActivity {

	private AlphaAnimation aa;
	private ImageView iv_splash;

	@Override
	protected void initView(Bundle savedInstanceState) {
		setContentView(R.layout.act_splash);
		
		
		
		iv_splash = (ImageView) findViewById(R.id.iv_splash);
		aa = new AlphaAnimation(0.1f, 1.0f);
		aa.setDuration(1000);
		iv_splash.setAnimation(aa);
	}

	@Override
	protected void initListener() {
		aa.setAnimationListener(new AnimationListener() {

			@Override
			public void onAnimationStart(Animation arg0) {

			}

			@Override
			public void onAnimationRepeat(Animation arg0) {

			}

			@Override
			public void onAnimationEnd(Animation arg0) {
				enterActivity(MainFragmentAct.class);
			}
		});
	}

	@Override
	protected void initData() {

	}

}
